Integrand size = 22, antiderivative size = 172 \[ \int \frac {A+B x^2}{a+b x^2+c x^4} \, dx=\frac {\left (B-\frac {b B-2 A c}{\sqrt {b^2-4 a c}}\right ) \arctan \left (\frac {\sqrt {2} \sqrt {c} x}{\sqrt {b-\sqrt {b^2-4 a c}}}\right )}{\sqrt {2} \sqrt {c} \sqrt {b-\sqrt {b^2-4 a c}}}+\frac {\left (B+\frac {b B-2 A c}{\sqrt {b^2-4 a c}}\right ) \arctan \left (\frac {\sqrt {2} \sqrt {c} x}{\sqrt {b+\sqrt {b^2-4 a c}}}\right )}{\sqrt {2} \sqrt {c} \sqrt {b+\sqrt {b^2-4 a c}}} \]
1/2*arctan(x*2^(1/2)*c^(1/2)/(b-(-4*a*c+b^2)^(1/2))^(1/2))*(B+(2*A*c-B*b)/ (-4*a*c+b^2)^(1/2))*2^(1/2)/c^(1/2)/(b-(-4*a*c+b^2)^(1/2))^(1/2)+1/2*arcta n(x*2^(1/2)*c^(1/2)/(b+(-4*a*c+b^2)^(1/2))^(1/2))*(B+(-2*A*c+B*b)/(-4*a*c+ b^2)^(1/2))*2^(1/2)/c^(1/2)/(b+(-4*a*c+b^2)^(1/2))^(1/2)
Time = 0.06 (sec) , antiderivative size = 173, normalized size of antiderivative = 1.01 \[ \int \frac {A+B x^2}{a+b x^2+c x^4} \, dx=\frac {\frac {\left (-b B+2 A c+B \sqrt {b^2-4 a c}\right ) \arctan \left (\frac {\sqrt {2} \sqrt {c} x}{\sqrt {b-\sqrt {b^2-4 a c}}}\right )}{\sqrt {b-\sqrt {b^2-4 a c}}}+\frac {\left (b B-2 A c+B \sqrt {b^2-4 a c}\right ) \arctan \left (\frac {\sqrt {2} \sqrt {c} x}{\sqrt {b+\sqrt {b^2-4 a c}}}\right )}{\sqrt {b+\sqrt {b^2-4 a c}}}}{\sqrt {2} \sqrt {c} \sqrt {b^2-4 a c}} \]
(((-(b*B) + 2*A*c + B*Sqrt[b^2 - 4*a*c])*ArcTan[(Sqrt[2]*Sqrt[c]*x)/Sqrt[b - Sqrt[b^2 - 4*a*c]]])/Sqrt[b - Sqrt[b^2 - 4*a*c]] + ((b*B - 2*A*c + B*Sq rt[b^2 - 4*a*c])*ArcTan[(Sqrt[2]*Sqrt[c]*x)/Sqrt[b + Sqrt[b^2 - 4*a*c]]])/ Sqrt[b + Sqrt[b^2 - 4*a*c]])/(Sqrt[2]*Sqrt[c]*Sqrt[b^2 - 4*a*c])
Time = 0.31 (sec) , antiderivative size = 172, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.091, Rules used = {1480, 218}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \frac {A+B x^2}{a+b x^2+c x^4} \, dx\) |
\(\Big \downarrow \) 1480 |
\(\displaystyle \frac {1}{2} \left (B-\frac {b B-2 A c}{\sqrt {b^2-4 a c}}\right ) \int \frac {1}{c x^2+\frac {1}{2} \left (b-\sqrt {b^2-4 a c}\right )}dx+\frac {1}{2} \left (\frac {b B-2 A c}{\sqrt {b^2-4 a c}}+B\right ) \int \frac {1}{c x^2+\frac {1}{2} \left (b+\sqrt {b^2-4 a c}\right )}dx\) |
\(\Big \downarrow \) 218 |
\(\displaystyle \frac {\left (B-\frac {b B-2 A c}{\sqrt {b^2-4 a c}}\right ) \arctan \left (\frac {\sqrt {2} \sqrt {c} x}{\sqrt {b-\sqrt {b^2-4 a c}}}\right )}{\sqrt {2} \sqrt {c} \sqrt {b-\sqrt {b^2-4 a c}}}+\frac {\left (\frac {b B-2 A c}{\sqrt {b^2-4 a c}}+B\right ) \arctan \left (\frac {\sqrt {2} \sqrt {c} x}{\sqrt {\sqrt {b^2-4 a c}+b}}\right )}{\sqrt {2} \sqrt {c} \sqrt {\sqrt {b^2-4 a c}+b}}\) |
((B - (b*B - 2*A*c)/Sqrt[b^2 - 4*a*c])*ArcTan[(Sqrt[2]*Sqrt[c]*x)/Sqrt[b - Sqrt[b^2 - 4*a*c]]])/(Sqrt[2]*Sqrt[c]*Sqrt[b - Sqrt[b^2 - 4*a*c]]) + ((B + (b*B - 2*A*c)/Sqrt[b^2 - 4*a*c])*ArcTan[(Sqrt[2]*Sqrt[c]*x)/Sqrt[b + Sqr t[b^2 - 4*a*c]]])/(Sqrt[2]*Sqrt[c]*Sqrt[b + Sqrt[b^2 - 4*a*c]])
3.2.9.3.1 Defintions of rubi rules used
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[a/b, 2]/a)*ArcTan[x/R t[a/b, 2]], x] /; FreeQ[{a, b}, x] && PosQ[a/b]
Int[((d_) + (e_.)*(x_)^2)/((a_) + (b_.)*(x_)^2 + (c_.)*(x_)^4), x_Symbol] : > With[{q = Rt[b^2 - 4*a*c, 2]}, Simp[(e/2 + (2*c*d - b*e)/(2*q)) Int[1/( b/2 - q/2 + c*x^2), x], x] + Simp[(e/2 - (2*c*d - b*e)/(2*q)) Int[1/(b/2 + q/2 + c*x^2), x], x]] /; FreeQ[{a, b, c, d, e}, x] && NeQ[b^2 - 4*a*c, 0] && NeQ[c*d^2 - a*e^2, 0] && PosQ[b^2 - 4*a*c]
Result contains higher order function than in optimal. Order 9 vs. order 3.
Time = 0.06 (sec) , antiderivative size = 45, normalized size of antiderivative = 0.26
method | result | size |
risch | \(\frac {\left (\munderset {\textit {\_R} =\operatorname {RootOf}\left (c \,\textit {\_Z}^{4}+\textit {\_Z}^{2} b +a \right )}{\sum }\frac {\left (B \,\textit {\_R}^{2}+A \right ) \ln \left (x -\textit {\_R} \right )}{2 c \,\textit {\_R}^{3}+\textit {\_R} b}\right )}{2}\) | \(45\) |
default | \(4 c \left (\frac {\left (-2 A c +B \sqrt {-4 a c +b^{2}}+B b \right ) \sqrt {2}\, \arctan \left (\frac {c x \sqrt {2}}{\sqrt {\left (b +\sqrt {-4 a c +b^{2}}\right ) c}}\right )}{8 \sqrt {-4 a c +b^{2}}\, c \sqrt {\left (b +\sqrt {-4 a c +b^{2}}\right ) c}}-\frac {\left (2 A c +B \sqrt {-4 a c +b^{2}}-B b \right ) \sqrt {2}\, \operatorname {arctanh}\left (\frac {c x \sqrt {2}}{\sqrt {\left (-b +\sqrt {-4 a c +b^{2}}\right ) c}}\right )}{8 \sqrt {-4 a c +b^{2}}\, c \sqrt {\left (-b +\sqrt {-4 a c +b^{2}}\right ) c}}\right )\) | \(164\) |
Leaf count of result is larger than twice the leaf count of optimal. 1569 vs. \(2 (138) = 276\).
Time = 0.44 (sec) , antiderivative size = 1569, normalized size of antiderivative = 9.12 \[ \int \frac {A+B x^2}{a+b x^2+c x^4} \, dx=\text {Too large to display} \]
1/2*sqrt(1/2)*sqrt(-(B^2*a*b - (4*A*B*a - A^2*b)*c + (a*b^2*c - 4*a^2*c^2) *sqrt((B^4*a^2 - 2*A^2*B^2*a*c + A^4*c^2)/(a^2*b^2*c^2 - 4*a^3*c^3)))/(a*b ^2*c - 4*a^2*c^2))*log(-2*(B^4*a^2 - A*B^3*a*b + A^3*B*b*c - A^4*c^2)*x + sqrt(1/2)*(A*B^2*a*b^2 + 4*A^3*a*c^2 - (4*A*B^2*a^2 + A^3*b^2)*c + (4*(2*B *a^3 - A*a^2*b)*c^2 - (2*B*a^2*b^2 - A*a*b^3)*c)*sqrt((B^4*a^2 - 2*A^2*B^2 *a*c + A^4*c^2)/(a^2*b^2*c^2 - 4*a^3*c^3)))*sqrt(-(B^2*a*b - (4*A*B*a - A^ 2*b)*c + (a*b^2*c - 4*a^2*c^2)*sqrt((B^4*a^2 - 2*A^2*B^2*a*c + A^4*c^2)/(a ^2*b^2*c^2 - 4*a^3*c^3)))/(a*b^2*c - 4*a^2*c^2))) - 1/2*sqrt(1/2)*sqrt(-(B ^2*a*b - (4*A*B*a - A^2*b)*c + (a*b^2*c - 4*a^2*c^2)*sqrt((B^4*a^2 - 2*A^2 *B^2*a*c + A^4*c^2)/(a^2*b^2*c^2 - 4*a^3*c^3)))/(a*b^2*c - 4*a^2*c^2))*log (-2*(B^4*a^2 - A*B^3*a*b + A^3*B*b*c - A^4*c^2)*x - sqrt(1/2)*(A*B^2*a*b^2 + 4*A^3*a*c^2 - (4*A*B^2*a^2 + A^3*b^2)*c + (4*(2*B*a^3 - A*a^2*b)*c^2 - (2*B*a^2*b^2 - A*a*b^3)*c)*sqrt((B^4*a^2 - 2*A^2*B^2*a*c + A^4*c^2)/(a^2*b ^2*c^2 - 4*a^3*c^3)))*sqrt(-(B^2*a*b - (4*A*B*a - A^2*b)*c + (a*b^2*c - 4* a^2*c^2)*sqrt((B^4*a^2 - 2*A^2*B^2*a*c + A^4*c^2)/(a^2*b^2*c^2 - 4*a^3*c^3 )))/(a*b^2*c - 4*a^2*c^2))) + 1/2*sqrt(1/2)*sqrt(-(B^2*a*b - (4*A*B*a - A^ 2*b)*c - (a*b^2*c - 4*a^2*c^2)*sqrt((B^4*a^2 - 2*A^2*B^2*a*c + A^4*c^2)/(a ^2*b^2*c^2 - 4*a^3*c^3)))/(a*b^2*c - 4*a^2*c^2))*log(-2*(B^4*a^2 - A*B^3*a *b + A^3*B*b*c - A^4*c^2)*x + sqrt(1/2)*(A*B^2*a*b^2 + 4*A^3*a*c^2 - (4*A* B^2*a^2 + A^3*b^2)*c - (4*(2*B*a^3 - A*a^2*b)*c^2 - (2*B*a^2*b^2 - A*a*...
Timed out. \[ \int \frac {A+B x^2}{a+b x^2+c x^4} \, dx=\text {Timed out} \]
\[ \int \frac {A+B x^2}{a+b x^2+c x^4} \, dx=\int { \frac {B x^{2} + A}{c x^{4} + b x^{2} + a} \,d x } \]
Leaf count of result is larger than twice the leaf count of optimal. 1402 vs. \(2 (138) = 276\).
Time = 0.78 (sec) , antiderivative size = 1402, normalized size of antiderivative = 8.15 \[ \int \frac {A+B x^2}{a+b x^2+c x^4} \, dx=\text {Too large to display} \]
1/4*((sqrt(2)*sqrt(b*c + sqrt(b^2 - 4*a*c)*c)*b^4 - 8*sqrt(2)*sqrt(b*c + s qrt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- 8*a^2*b^2*c - 2*a*b^3*c + 16*a^3*c^ 2 + 8*a^2*b*c^2 + a*b^2*c^2 - 4*a^2*c^3)*abs(c)) + 1/4*((sqrt(2)*sqrt(b*c - sqrt(b^2 - 4*a*c)*c)*b^4 - 8*sqrt(2)*sqrt(b*c - sqrt(b^2 - 4*a*c)*c)*a*b ^2*c - 2*sqrt(2)*sqrt(b*c - sqrt(b^2 - 4*a*c)*c)*b^3*c + 2*b^4*c + 16*sqrt (2)*sqrt(b*c - sqrt(b^2 - 4*a*c)*c)*a^2*c^2 + 8*sqrt(2)*sqrt(b*c - sqrt...
Time = 8.07 (sec) , antiderivative size = 4109, normalized size of antiderivative = 23.89 \[ \int \frac {A+B x^2}{a+b x^2+c x^4} \, dx=\text {Too large to display} \]
- atan((((-(B^2*a*b^3 + B^2*a*(-(4*a*c - b^2)^3)^(1/2) + A^2*b^3*c - A^2*c *(-(4*a*c - b^2)^3)^(1/2) + 16*A*B*a^2*c^2 - 4*A^2*a*b*c^2 - 4*B^2*a^2*b*c - 4*A*B*a*b^2*c)/(8*(16*a^3*c^3 - 8*a^2*b^2*c^2 + a*b^4*c)))^(1/2)*(x*(8* b^3*c^2 - 32*a*b*c^3)*(-(B^2*a*b^3 + B^2*a*(-(4*a*c - b^2)^3)^(1/2) + A^2* b^3*c - A^2*c*(-(4*a*c - b^2)^3)^(1/2) + 16*A*B*a^2*c^2 - 4*A^2*a*b*c^2 - 4*B^2*a^2*b*c - 4*A*B*a*b^2*c)/(8*(16*a^3*c^3 - 8*a^2*b^2*c^2 + a*b^4*c))) ^(1/2) - 4*A*b^2*c^2 + 16*A*a*c^3) + x*(4*A^2*c^3 - 4*B^2*a*c^2 + 2*B^2*b^ 2*c - 4*A*B*b*c^2))*(-(B^2*a*b^3 + B^2*a*(-(4*a*c - b^2)^3)^(1/2) + A^2*b^ 3*c - A^2*c*(-(4*a*c - b^2)^3)^(1/2) + 16*A*B*a^2*c^2 - 4*A^2*a*b*c^2 - 4* B^2*a^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